package impl_v1;

import model.AuctionPrivate;
import model.Item;

public class AuctionPrivateImpl extends AuctionPublicImpl implements AuctionPrivate {

	private static final long serialVersionUID = -8649460311619922127L;
	private final int reservePrice;
	private final int key;

	public AuctionPrivateImpl(int reservePrice, int key, int startingPrice, Item item) {
		super(startingPrice, item);
		this.reservePrice = reservePrice;
		this.key = key;
	}

	@Override
	public int getReservePrice() {
		return reservePrice;
	}

	@Override
	public int getKey() {
		return key;
	}

	@Override
	public void setClosed() {
		closed = true;
	}

	@Override
	public String toString() {
		return "AuctionPrivateImpl[reservePrice=" + reservePrice + ", startingPrice=" + getStartingPrice() + ", bid=" + getBid()
				+ ", key=" + key + ", item=" + getItem() + "]";
	}

}
